package com.yc.backstage.mapper;

import com.yc.backstage.entity.SysPost;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
* @Classname SysPostController
* @Description
* @Version 1.0.0
* @Date 2022-08-23 11:49:19
* @Created by Mikechen
*/
@Mapper
public interface SysPostMapper extends BaseMapper<SysPost> {
    /**
     * 查询用户所属岗位组
     *
     * @param userName 用户名
     * @return 结果
     */
     List<SysPost> selectPostsByUserName(String userName);

    /**
     * 查询所有岗位
     * @return
     */
    List<SysPost> selectPsotAll();

    /**
     * 根据用户id查询用户的岗位信息
     * @param userId
     * @return
     */
    List<Long> selectPsotByUserId(Long userId);
}
